﻿using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Windows.Forms;
using ITAP.ShprossesBuilder.Manipulation;
using ITAP.ShprossesBuilder;
using ITAP.ShprossesBuilder.Modelling.Components.Actions;

namespace ITAP.ShprossesBuilder.Editor
{
    public partial class AlignComponentsForm : Form
    {
        private bool moveConnectedComponents = false;

        public bool MoveConnectedComponents
        {
            get { return moveConnectedComponents; }
        }

        private ComponentAlign align;

        public ComponentAlign Align
        {
            get { return align; }
        }
        public AlignComponentsForm(bool moveConnectedComponentsVisible)
        {
            InitializeComponent();
            this.comboBoxAlignType.SelectedIndex = 0;
            checkBoxMoveConnectedComponents.Visible = moveConnectedComponentsVisible;

        }

        private void radioButton2_CheckedChanged(object sender, EventArgs e)
        {

        }

        private void comboBoxAlignType_TextUpdate(object sender, EventArgs e)
        {

        }

        private void buttonOK_Click(object sender, EventArgs e)
        {
            if (this.comboBoxAlignType.Text == "горизонтали")
                align = ComponentAlign.Horizontal;
            else
                align = ComponentAlign.Vertical;

            moveConnectedComponents = checkBoxMoveConnectedComponents.Checked;
        }
    }
}
